package yuan;

import javax.swing.tree.TreeNode;
import java.util.ArrayList;
import java.util.LinkedList;
import java.util.List;
import java.util.Queue;

/**
 * @version: 1.0
 * @Description: TODO
 * @author: zZmH
 * @date: 2020/09/14 19:32
 */





class Solution {
        public boolean isOneBitCharacter(int[] bits) {
            int len = bits.length;
            if(len%2==1)
                return true;

            len=len-2;
            int last = len + 1;
            while(len>=0){

                if(bits[last]==0&&bits[len]==0)
                    return true;
                last = bits[len];

                len--;
            }
            return false;

        }

    public static void main(String[] args) {

        System.out.println(new Solution().isOneBitCharacter(new int[]{0,0}));
    }
    }